# SOURCE
namespace eval ::tank {
    variable path
    set path [uplevel #0 {file dirname [info script]}]
}
set devDir [file join $::tank::path dev]
foreach f [glob -nocomplain -directory $devDir *] {
    if [file isfile $f] { source [file join $devDir $f] }
}

# LIB PATH
lappend auto_path [file join $::tank::path lib]

# IMPORT
namespace import ::contrib::*

# PROJECT ROOT DIRECTORY
set projectRoot [projectRoot]

# AUTO_PATH
lappend auto_path [file join $projectRoot lib]

# MAIN
if [catch {
    set file [file join $::tank::path src [lindex $argv 0].tcl]
    set argv [lreplace $argv 0 0]
    source $file
} _err] {
    puts "$_err\n$errorInfo"
    ::contrib::log::info "Sorry, there is no such parameter.\nParameter should be one of new, test, deps."
}
